package org.lvgo.filter;

import java.util.List;
import java.util.stream.Collectors;

/**
 * 已婚过滤器
 *
 * @author lvgo
 * @version 1.0
 * @date 2018/9/21 0021 17:18
 */
public class MarriedFilter implements Criteria {
    @Override
    public List<Person> filterPerson(List<Person> people) {
        return people.stream().filter(Person::isMarried).collect(Collectors.toList());
    }
}
